use serde::{Deserialize, Serialize};
use solana_sdk::pubkey::Pubkey;
use std::time::SystemTime;

#[derive(Debug, Clone)]
pub struct Position {
    pub pool_id: Pubkey,
    pub token_mint: Pubkey,
    pub buy_time: SystemTime,
    pub buy_amount: u64,
    pub token_balance: u64,
    pub buy_price: f64,
}

#[derive(Debug, Deserialize)]
pub struct WebSocketMessage {
    pub jsonrpc: String,
    pub method: Option<String>,
    pub params: Option<serde_json::Value>,
}

#[derive(Debug, Serialize)]
pub struct SubscribeMessage {
    pub jsonrpc: String,
    pub id: u32,
    pub method: String,
    pub params: Vec<serde_json::Value>,
}

#[derive(Debug, Clone)]
pub struct PoolInfo {
    pub id: Pubkey,
    pub mint_a: Pubkey,
    pub mint_b: Pubkey,
    pub liquidity_sol: f64,
    pub liquidity_wsol: f64,
}

#[derive(Debug)]
pub struct TokenValidation {
    pub is_mint_renounced: bool,
    pub is_not_freezable: bool,
    pub liquidity_in_range: bool,
} 